# Required
install.packages("doParallel")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/doParallel_1.0.15.tgz'
Content type 'application/x-gzip' length 196281 bytes (191 KB)
==================================================
downloaded 191 KB
The downloaded binary packages are in
/var/folders/hm/2md7sccd0479bw81zsh0yyq80000gn/T//RtmpMt7cbP/downloaded_packages
library(doParallel)
Loading required package: foreach
Loading required package: iterators
Loading required package: parallel
# Find how many cores are on your machine
detectCores() # Result = Typically 4 to 6
[1] 4
# Create Cluster with desired number of cores. Don't use them all! Your computer is running other processes.
cl <- makeCluster(2)
# Register Cluster
registerDoParallel(cl)
# Confirm how many cores are now "assigned" to R and RStudio
getDoParWorkers() # Result 2
[1] 2
# create reproducable results from random sampling
set.seed(234)
# Stop Cluster. After performing your tasks, stop your cluster.
stopCluster(cl)
install.packages("caret")
Error in install.packages : Updating loaded packages
install.packages("plotly")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/plotly_4.9.2.tgz'
Content type 'application/x-gzip' length 2987045 bytes (2.8 MB)
==================================================
downloaded 2.8 MB
The downloaded binary packages are in
/var/folders/hm/2md7sccd0479bw81zsh0yyq80000gn/T//RtmpzDtPJ5/downloaded_packages
install.packages("caret")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/caret_6.0-85.tgz'
Content type 'application/x-gzip' length 6264988 bytes (6.0 MB)
==================================================
downloaded 6.0 MB
The downloaded binary packages are in
/var/folders/hm/2md7sccd0479bw81zsh0yyq80000gn/T//RtmpzDtPJ5/downloaded_packages
install.packages("dplyr")
Error in install.packages : Updating loaded packages
install.packages("kknn")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/kknn_1.3.1.tgz'
Content type 'application/x-gzip' length 320274 bytes (312 KB)
==================================================
downloaded 312 KB
The downloaded binary packages are in
/var/folders/hm/2md7sccd0479bw81zsh0yyq80000gn/T//RtmpzDtPJ5/downloaded_packages
install.packages("dplyr")
There is a binary version available but the source version is later:
no
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/dplyr_0.8.4.tgz'
Content type 'application/x-gzip' length 6846395 bytes (6.5 MB)
==================================================
downloaded 6.5 MB
The downloaded binary packages are in
/var/folders/hm/2md7sccd0479bw81zsh0yyq80000gn/T//RtmpzDtPJ5/downloaded_packages
install.packages("corrplot")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/corrplot_0.84.tgz'
Content type 'application/x-gzip' length 5452777 bytes (5.2 MB)
==================================================
downloaded 5.2 MB
The downloaded binary packages are in
/var/folders/hm/2md7sccd0479bw81zsh0yyq80000gn/T//RtmpzDtPJ5/downloaded_packages
install.packages("corrr")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/corrr_0.4.1.tgz'
Content type 'application/x-gzip' length 131240 bytes (128 KB)
==================================================
downloaded 128 KB
The downloaded binary packages are in
/var/folders/hm/2md7sccd0479bw81zsh0yyq80000gn/T//RtmpzDtPJ5/downloaded_packages
library(dplyr)
Attaching package: ‘dplyr’
The following objects are masked from ‘package:stats’:
filter, lag
The following objects are masked from ‘package:base’:
intersect, setdiff, setequal, union
options(max.print=1000000)
options(scipen=999)
largeMatrix <- read.csv("LargeMatrix.csv")
# no nas present
sum(is.na(largeMatrix))
[1] 0
iphone_smallMatrix <- read.csv("iphone_smallmatrix_labeled_8d.csv")
samsung_smallMatrix <- read.csv("galaxy_smallmatrix_labeled_9d.csv")
names(iphone_smallMatrix)
[1] "iphone" "samsunggalaxy" "sonyxperia" "nokialumina" "htcphone"
[6] "ios" "googleandroid" "iphonecampos" "samsungcampos" "sonycampos"
[11] "nokiacampos" "htccampos" "iphonecamneg" "samsungcamneg" "sonycamneg"
[16] "nokiacamneg" "htccamneg" "iphonecamunc" "samsungcamunc" "sonycamunc"
[21] "nokiacamunc" "htccamunc" "iphonedispos" "samsungdispos" "sonydispos"
[26] "nokiadispos" "htcdispos" "iphonedisneg" "samsungdisneg" "sonydisneg"
[31] "nokiadisneg" "htcdisneg" "iphonedisunc" "samsungdisunc" "sonydisunc"
[36] "nokiadisunc" "htcdisunc" "iphoneperpos" "samsungperpos" "sonyperpos"
[41] "nokiaperpos" "htcperpos" "iphoneperneg" "samsungperneg" "sonyperneg"
[46] "nokiaperneg" "htcperneg" "iphoneperunc" "samsungperunc" "sonyperunc"
[51] "nokiaperunc" "htcperunc" "iosperpos" "googleperpos" "iosperneg"
[56] "googleperneg" "iosperunc" "googleperunc" "iphonesentiment"
names(samsung_smallMatrix)
[1] "iphone" "samsunggalaxy" "sonyxperia" "nokialumina" "htcphone"
[6] "ios" "googleandroid" "iphonecampos" "samsungcampos" "sonycampos"
[11] "nokiacampos" "htccampos" "iphonecamneg" "samsungcamneg" "sonycamneg"
[16] "nokiacamneg" "htccamneg" "iphonecamunc" "samsungcamunc" "sonycamunc"
[21] "nokiacamunc" "htccamunc" "iphonedispos" "samsungdispos" "sonydispos"
[26] "nokiadispos" "htcdispos" "iphonedisneg" "samsungdisneg" "sonydisneg"
[31] "nokiadisneg" "htcdisneg" "iphonedisunc" "samsungdisunc" "sonydisunc"
[36] "nokiadisunc" "htcdisunc" "iphoneperpos" "samsungperpos" "sonyperpos"
[41] "nokiaperpos" "htcperpos" "iphoneperneg" "samsungperneg" "sonyperneg"
[46] "nokiaperneg" "htcperneg" "iphoneperunc" "samsungperunc" "sonyperunc"
[51] "nokiaperunc" "htcperunc" "iosperpos" "googleperpos" "iosperneg"
[56] "googleperneg" "iosperunc" "googleperunc" "galaxysentiment"
#summary(iphone_smallMatrix$ios)
str(iphone_smallMatrix)
'data.frame': 12973 obs. of 59 variables:
$ iphone : int 1 1 1 1 1 41 1 1 1 1 ...
$ samsunggalaxy : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonyxperia : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokialumina : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcphone : int 0 0 0 0 0 0 0 0 0 0 ...
$ ios : int 0 0 0 0 0 6 0 0 0 0 ...
$ googleandroid : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonecampos : int 0 0 0 0 0 1 1 0 0 0 ...
$ samsungcampos : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonycampos : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiacampos : int 0 0 0 0 0 0 0 0 0 0 ...
$ htccampos : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonecamneg : int 0 0 0 0 0 3 1 0 0 0 ...
$ samsungcamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonycamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiacamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ htccamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonecamunc : int 0 0 0 0 0 7 1 0 0 0 ...
$ samsungcamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonycamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiacamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ htccamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonedispos : int 0 0 0 0 0 1 13 0 0 0 ...
$ samsungdispos : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonydispos : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiadispos : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcdispos : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonedisneg : int 0 0 0 0 0 3 10 0 0 0 ...
$ samsungdisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonydisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiadisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcdisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonedisunc : int 0 0 0 0 0 4 9 0 0 0 ...
$ samsungdisunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonydisunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiadisunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcdisunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphoneperpos : int 0 1 0 1 1 0 5 3 0 0 ...
$ samsungperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonyperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiaperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphoneperneg : int 0 0 0 0 0 0 4 1 0 0 ...
$ samsungperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonyperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiaperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphoneperunc : int 0 0 0 1 0 0 5 0 0 0 ...
$ samsungperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonyperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiaperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ iosperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ googleperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ iosperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ googleperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ iosperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ googleperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonesentiment: int 0 0 0 0 0 4 4 0 0 0 ...
str(samsung_smallMatrix)
'data.frame': 12911 obs. of 59 variables:
$ iphone : int 1 1 1 0 1 2 1 1 4 1 ...
$ samsunggalaxy : int 0 0 1 0 0 0 0 0 0 0 ...
$ sonyxperia : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokialumina : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcphone : int 0 0 0 1 0 0 0 0 0 0 ...
$ ios : int 0 0 0 0 0 0 0 0 0 0 ...
$ googleandroid : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonecampos : int 0 0 1 0 0 1 0 0 0 0 ...
$ samsungcampos : int 0 0 1 0 0 0 0 0 0 0 ...
$ sonycampos : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiacampos : int 0 0 0 0 0 0 0 0 0 0 ...
$ htccampos : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonecamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ samsungcamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonycamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiacamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ htccamneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonecamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ samsungcamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonycamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiacamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ htccamunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonedispos : int 0 1 0 0 0 0 2 0 0 0 ...
$ samsungdispos : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonydispos : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiadispos : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcdispos : int 0 0 0 1 0 0 0 0 0 0 ...
$ iphonedisneg : int 0 1 0 0 0 0 0 0 0 0 ...
$ samsungdisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonydisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiadisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcdisneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ iphonedisunc : int 0 1 0 0 0 0 0 0 0 0 ...
$ samsungdisunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonydisunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiadisunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcdisunc : int 0 0 0 1 0 0 0 0 0 0 ...
$ iphoneperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ samsungperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonyperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiaperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcperpos : int 0 0 0 1 0 0 0 0 0 0 ...
$ iphoneperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ samsungperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonyperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiaperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcperneg : int 0 0 0 1 0 0 0 0 0 0 ...
$ iphoneperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ samsungperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ sonyperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ nokiaperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ htcperunc : int 0 0 0 1 0 0 0 0 0 0 ...
$ iosperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ googleperpos : int 0 0 0 0 0 0 0 0 0 0 ...
$ iosperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ googleperneg : int 0 0 0 0 0 0 0 0 0 0 ...
$ iosperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ googleperunc : int 0 0 0 0 0 0 0 0 0 0 ...
$ galaxysentiment: int 5 3 3 0 1 0 3 5 5 5 ...
# no missing values
sum(is.na(iphone_smallMatrix))
[1] 0
sum(is.na(samsung_smallMatrix))
[1] 0
# There are no empty columns
colSums(iphone_smallMatrix)
iphone samsunggalaxy sonyxperia nokialumina htcphone ios
27867 923 312 30 1779 1976
googleandroid iphonecampos samsungcampos sonycampos nokiacampos htccampos
514 3757 697 129 89 1469
iphonecamneg samsungcamneg sonycamneg nokiacamneg htccamneg iphonecamunc
3044 710 30 80 1206 3289
samsungcamunc sonycamunc nokiacamunc htccamunc iphonedispos samsungdispos
243 42 47 611 9304 819
sonydispos nokiadispos htcdispos iphonedisneg samsungdisneg sonydisneg
148 129 2051 7894 856 161
nokiadisneg htcdisneg iphonedisunc samsungdisunc sonydisunc nokiadisunc
103 1509 6550 352 59 64
htcdisunc iphoneperpos samsungperpos sonyperpos nokiaperpos htcperpos
812 7854 803 112 138 1660
iphoneperneg samsungperneg sonyperneg nokiaperneg htcperneg iphoneperunc
6313 832 83 133 1562 3880
samsungperunc sonyperunc nokiaperunc htcperunc iosperpos googleperpos
287 30 72 832 768 500
iosperneg googleperneg iosperunc googleperunc iphonesentiment
747 755 429 209 48318
colSums(samsung_smallMatrix)
iphone samsunggalaxy sonyxperia nokialumina htcphone ios
28525 921 311 30 1775 1972
googleandroid iphonecampos samsungcampos sonycampos nokiacampos htccampos
513 3733 693 125 89 1461
iphonecamneg samsungcamneg sonycamneg nokiacamneg htccamneg iphonecamunc
3027 710 30 80 1202 3278
samsungcamunc sonycamunc nokiacamunc htccamunc iphonedispos samsungdispos
241 40 47 608 9251 814
sonydispos nokiadispos htcdispos iphonedisneg samsungdisneg sonydisneg
143 129 2039 7849 856 161
nokiadisneg htcdisneg iphonedisunc samsungdisunc sonydisunc nokiadisunc
103 1501 6519 351 58 64
htcdisunc iphoneperpos samsungperpos sonyperpos nokiaperpos htcperpos
810 7786 801 110 138 1653
iphoneperneg samsungperneg sonyperneg nokiaperneg htcperneg iphoneperunc
6269 832 83 133 1559 3847
samsungperunc sonyperunc nokiaperunc htcperunc iosperpos googleperpos
285 28 72 829 768 500
iosperneg googleperneg iosperunc googleperunc galaxysentiment
747 755 429 209 49430
plot_ly(iphone_smallMatrix, x= ~iphone_smallMatrix$iphonesentiment, type='histogram')
plot_ly(samsung_smallMatrix, x= ~samsung_smallMatrix$galaxysentiment, type='histogram')
NA
Notes: 0: very negative 1: negative 2: somewhat negative 3: somewhat positive 4: positive 5: very positive
Note to self:We already have too many innecessary predictors, including google, nokia, htc, and sony phones. We are only looking for samsung galaxy and iphone.
# correlation matrix
corr_matrixBIG <- cor(iphone_smallMatrix)
corr_plotBIG <- corrplot(as.matrix(corr_matrixBIG))
corr_plotBIG
iphone samsunggalaxy sonyxperia nokialumina htcphone
iphone 1.000000000 0.0197858228 -0.011617908 -0.0134231660 -0.00273072716
samsunggalaxy 0.019785823 1.0000000000 0.366670822 -0.0060880044 0.01789861865
sonyxperia -0.011617908 0.3666708219 1.000000000 -0.0063498609 0.02368195645
nokialumina -0.013423166 -0.0060880044 -0.006349861 1.0000000000 0.00067310272
htcphone -0.002730727 0.0178986186 0.023681956 0.0006731027 1.00000000000
ios 0.922060288 -0.0446783638 -0.023883554 -0.0028193921 -0.00500247141
googleandroid 0.107530021 0.2361624448 -0.018288470 -0.0011148600 0.01649835098
iphonecampos 0.078157326 0.0305561602 0.005067537 0.0298240731 0.00695241462
samsungcampos 0.057395445 0.2521205947 0.050139994 0.0092986543 0.01086477716
sonycampos -0.004593694 0.1459691107 0.396750611 -0.0027543180 0.01043247542
nokiacampos -0.008439469 -0.0004004217 -0.004231735 0.7004150055 0.00046460943
htccampos 0.022717373 0.0652742531 0.016506652 0.0212952463 0.02318862624
iphonecamneg 0.490523588 0.1260628010 -0.006715050 0.0632452640 0.01415477596
samsungcamneg 0.142552547 0.3429191699 -0.004308481 0.0095460787 0.02002142103
sonycamneg -0.001830062 0.0318207535 0.345295791 -0.0012288604 0.00490893019
nokiacamneg -0.009186004 -0.0009794805 -0.004467233 0.7294341201 0.00019108337
htccamneg 0.104612765 0.2227765630 -0.012284395 0.0372556408 0.03676527571
iphonecamunc 0.750403174 -0.0101550995 -0.007638359 0.0162370821 0.00117399793
samsungcamunc 0.073451360 0.3161343514 0.058776666 0.0409222547 0.01564382597
sonycamunc -0.003064444 0.1041234759 0.376632870 -0.0019143276 0.00984294811
nokiacamunc -0.008602174 0.0056913189 -0.003972104 0.6341714578 0.00036405549
htccamunc 0.026137801 0.0729644969 0.014249220 0.0361240923 0.02915249517
iphonedispos 0.052624621 -0.0065259392 -0.018121019 0.0283164282 0.00025257329
samsungdispos 0.061074202 0.2813785961 0.040062534 0.0414557439 0.01314540480
sonydispos -0.003826569 0.0613598274 0.252589216 -0.0015281417 0.00695873598
nokiadispos -0.008202154 0.0102477757 -0.003772222 0.6502528013 0.00031111754
htcdispos 0.007124916 0.0248386343 0.003299105 0.0105537205 0.97753800394
iphonedisneg 0.175572621 0.0178241295 -0.013589598 0.0237416752 0.00279630126
samsungdisneg 0.111821338 0.3043854457 0.007706073 0.0229101893 0.02015424694
sonydisneg -0.002777449 0.0067858231 0.163285424 -0.0006439773 0.00305632503
nokiadisneg -0.008789651 0.0056401787 -0.004039779 0.6922675788 0.00038854947
htcdisneg 0.085273338 0.1888214611 -0.002137681 0.0442224554 0.03765330142
iphonedisunc 0.250929821 -0.0278792236 -0.017980754 0.0026813370 -0.00210838912
samsungdisunc 0.038726564 0.1900383992 0.026313761 0.0468960989 0.00941332878
sonydisunc -0.004552958 0.0605561472 0.295428494 -0.0013832449 0.00526783960
nokiadisunc -0.007588080 0.0146608209 -0.003233038 0.4913317753 -0.00006612816
htcdisunc 0.024321607 0.0717456027 0.010002504 0.0211143866 0.02919531316
iphoneperpos -0.009507666 -0.0031694293 -0.028717034 0.0333454788 0.00012136011
samsungperpos 0.051538330 0.2428663875 0.020914013 0.0174590583 0.00971056143
sonyperpos -0.006326680 0.0674892485 0.266141716 -0.0019186794 0.00481191845
nokiaperpos -0.010508929 0.0018461920 -0.004606023 0.7374571504 0.00045448519
htcperpos 0.030621280 0.0882886778 0.004676818 0.0391126464 0.03090921713
iphoneperneg 0.013863107 0.0459625861 -0.028774205 0.0337354136 0.00428474660
samsungperneg 0.115130047 0.3035599053 -0.001931200 0.0173540315 0.01745747193
sonyperneg -0.003624744 0.0099767986 0.122406709 -0.0009478623 0.00111336490
nokiaperneg -0.010780939 0.0004813798 -0.004699284 0.7364531206 0.00046239234
htcperneg 0.075975448 0.1784097437 -0.012082758 0.0500508027 0.03394178233
iphoneperunc -0.016037424 -0.0173890375 -0.028220476 0.0201971628 0.00019418976
samsungperunc 0.046821536 0.1847750567 0.008007867 0.0352741223 0.01064355437
sonyperunc -0.003045401 0.0374818698 0.151675102 -0.0012035022 0.00501769982
nokiaperunc -0.009704196 0.0073052108 -0.004253312 0.6484414145 0.00011221050
htcperunc 0.011414261 0.0449278125 -0.004888049 0.0237567173 0.02144814516
iosperpos -0.020059363 -0.0058016799 -0.011009239 0.0307188669 -0.00292694652
googleperpos 0.118008345 0.2460460932 -0.008467307 0.0065145374 0.01918647393
iosperneg -0.019081100 -0.0078393527 -0.010322710 0.0327209185 -0.00275835644
googleperneg 0.138742360 0.2909745336 -0.008569847 0.0006534676 0.02072613677
iosperunc -0.020368118 -0.0153292775 -0.014802411 0.0528866876 -0.00266622995
googleperunc 0.067859235 0.1422517633 -0.007916030 0.0079987614 0.01330495414
iphonesentiment 0.014858654 -0.3591727604 -0.233169880 -0.0559617692 -0.05128486819
ios googleandroid iphonecampos samsungcampos sonycampos
iphone 0.9220602880 0.1075300211 0.078157326 0.057395445 -0.004593694
samsunggalaxy -0.0446783638 0.2361624448 0.030556160 0.252120595 0.145969111
sonyxperia -0.0238835536 -0.0182884699 0.005067537 0.050139994 0.396750611
nokialumina -0.0028193921 -0.0011148600 0.029824073 0.009298654 -0.002754318
htcphone -0.0050024714 0.0164983510 0.006952415 0.010864777 0.010432475
ios 1.0000000000 -0.0264036366 0.042128140 -0.010741408 -0.009369477
googleandroid -0.0264036366 1.0000000000 0.104419788 0.315487421 -0.000205677
iphonecampos 0.0421281400 0.1044197879 1.000000000 0.062438375 0.045008555
samsungcampos -0.0107414079 0.3154874208 0.062438375 1.000000000 0.145429114
sonycampos -0.0093694774 -0.0002056770 0.045008555 0.145429114 1.000000000
nokiacampos 0.0054250755 0.0032844953 0.030816940 0.014860360 -0.001835559
htccampos -0.0123897510 0.1480948517 0.623911948 0.090099060 0.058852134
iphonecamneg 0.3869664642 0.3918021616 0.541339970 0.206019550 0.013254078
samsungcamneg -0.0152725698 0.7114026076 0.117450549 0.608840260 0.032897238
sonycamneg -0.0038538548 0.0135394518 0.019994295 0.053984838 0.408990574
nokiacamneg 0.0046513511 -0.0018238625 0.026855480 0.014368271 -0.001937709
htccamneg -0.0230487872 0.5627028612 0.206584693 0.295428414 0.013568090
iphonecamunc 0.7326117106 0.0429551472 0.473266316 0.028875432 0.016442392
samsungcamunc -0.0123900968 0.3914328531 0.076943199 0.814799293 0.164043120
sonycamunc -0.0064841085 -0.0065777411 0.029397327 0.098836218 0.528452314
nokiacamunc 0.0063413897 0.0003252623 0.021277308 0.028322579 -0.001722941
htccamunc -0.0157845325 0.1661818489 0.321523039 0.104495332 0.056574443
iphonedispos 0.0143768878 0.0669526940 0.272586547 0.039427134 0.019616805
samsungdispos -0.0099064670 0.3161320233 0.060476039 0.643691775 0.111287385
sonydispos 0.0042066852 -0.0016689972 0.017749083 0.058122227 0.404993025
nokiadispos 0.0030652805 -0.0041735324 0.026317276 0.038370716 -0.001636240
htcdispos -0.0057487757 0.0575517863 0.067428991 0.032923476 0.016457151
iphonedisneg 0.1137836285 0.1218206151 0.148650674 0.065278833 0.006716763
samsungdisneg -0.0117059583 0.5424396400 0.089812938 0.487871125 0.058932439
sonydisneg 0.0080627604 0.0002154346 0.002884403 0.011236169 0.131891912
nokiadisneg 0.0034323575 -0.0044695534 0.026306571 0.028454242 -0.001752296
htcdisneg -0.0197092424 0.4470127937 0.110101690 0.238425394 0.037623834
iphonedisunc 0.2188348739 0.0177913687 0.188310035 0.012312670 0.007383581
samsungdisunc -0.0059508636 0.1889243479 0.035791405 0.389689453 0.089488968
sonydisunc 0.0006261928 -0.0047529101 0.019403175 0.067667721 0.388803630
nokiadisunc 0.0061101654 -0.0035769868 0.009608304 0.046811518 -0.001402364
htcdisunc -0.0126521639 0.1470680904 0.156063063 0.086766462 0.055055469
iphoneperpos -0.0219530895 0.1060606249 0.348332416 0.056272259 0.009152257
samsungperpos -0.0021308395 0.2703549368 0.045221267 0.793898531 0.046922592
sonyperpos -0.0040906577 0.0008356533 0.013944374 0.047395270 0.387310836
nokiaperpos 0.0022605934 -0.0022999416 0.021177553 0.021581165 -0.001997910
htcperpos -0.0181673563 0.2094141916 0.287084655 0.115131849 0.021325928
iphoneperneg -0.0125664931 0.2125251416 0.151918629 0.112507527 0.006280325
samsungperneg -0.0071679631 0.5580899386 0.092030029 0.546669519 0.034148912
sonyperneg -0.0029023760 0.0056565738 0.007034030 0.019365699 0.182829435
nokiaperneg 0.0023215759 -0.0032259170 0.017987195 0.018696148 -0.002038363
htcperneg -0.0215760696 0.4334113667 0.109391575 0.231171524 0.009013357
iphoneperunc -0.0154819150 0.0566763832 0.187259620 0.031844675 0.008176179
samsungperunc -0.0047703474 0.2217259668 0.040154370 0.487766617 0.053436363
sonyperunc -0.0048317142 -0.0041353037 0.019987020 0.057860036 0.378811803
nokiaperunc 0.0050302440 -0.0014066039 0.014826530 0.033196650 -0.001844918
htcperunc -0.0119295874 0.1096851420 0.067283071 0.061303831 0.015781446
iosperpos 0.1182783271 -0.0167016726 -0.003991076 0.102471444 -0.003118246
googleperpos -0.0164015981 0.6385807446 0.117901901 0.298281304 0.006672666
iosperneg 0.1123297684 -0.0158253040 -0.007059840 0.075694836 -0.002863268
googleperneg -0.0180284915 0.7165147742 0.124354761 0.357362406 0.008454560
iosperunc 0.1170349668 -0.0163771745 -0.001037094 0.044889715 -0.006420699
googleperunc -0.0102331140 0.3719984702 0.073003914 0.159171496 -0.003433660
iphonesentiment 0.0016564175 -0.1891420499 -0.029731217 -0.112743311 -0.090665090
nokiacampos htccampos iphonecamneg samsungcamneg sonycamneg
iphone -0.0084394692 0.022717373 0.490523588 0.142552547 -0.0018300621
samsunggalaxy -0.0004004217 0.065274253 0.126062801 0.342919170 0.0318207535
sonyxperia -0.0042317350 0.016506652 -0.006715050 -0.004308481 0.3452957914
nokialumina 0.7004150055 0.021295246 0.063245264 0.009546079 -0.0012288604
htcphone 0.0004646094 0.023188626 0.014154776 0.020021421 0.0049089302
ios 0.0054250755 -0.012389751 0.386966464 -0.015272570 -0.0038538548
googleandroid 0.0032844953 0.148094852 0.391802162 0.711402608 0.0135394518
iphonecampos 0.0308169399 0.623911948 0.541339970 0.117450549 0.0199942953
samsungcampos 0.0148603600 0.090099060 0.206019550 0.608840260 0.0539848377
sonycampos -0.0018355589 0.058852134 0.013254078 0.032897238 0.4089905736
nokiacampos 1.0000000000 0.017761487 0.053371499 0.016046872 -0.0008189489
htccampos 0.0177614870 1.000000000 0.206896901 0.171078711 0.0161964828
iphonecamneg 0.0533714992 0.206896901 1.000000000 0.468562960 0.0655977000
samsungcamneg 0.0160468719 0.171078711 0.468562960 1.000000000 0.0723697042
sonycamneg -0.0008189489 0.016196483 0.065597700 0.072369704 1.0000000000
nokiacamneg 0.9142720770 0.015395819 0.070242502 0.015465263 -0.0008645238
htccamneg 0.0305012877 0.450715453 0.507638049 0.661017063 0.0380034764
iphonecamunc 0.0186364023 0.163480446 0.643460020 0.061619492 0.0250592852
samsungcamunc 0.0580378785 0.113420510 0.262665362 0.703837836 0.1286197355
sonycamunc -0.0012757645 0.037328532 0.034024096 0.050762079 0.6030047959
nokiacamunc 0.9402208771 0.014926110 0.037266523 0.031131313 -0.0007687037
htccamunc 0.0285796837 0.656659442 0.238011225 0.200439201 0.0367016156
iphonedispos 0.0292070224 0.129812956 0.261983142 0.079343436 0.0248279099
samsungdispos 0.0584103282 0.083526364 0.200390891 0.545463046 0.1099126590
sonydispos -0.0010183988 0.022015622 0.015890753 0.037424924 0.3372117408
nokiadispos 0.8708585691 0.014629187 0.050013170 0.042391084 -0.0007300214
htcdispos 0.0088485247 0.140446973 0.055439580 0.065595998 0.0151478630
iphonedisneg 0.0221700030 0.041086089 0.346878956 0.152069590 0.0400385215
samsungdisneg 0.0336832170 0.131056692 0.350114204 0.755771365 0.1199730012
sonydisneg -0.0004291655 0.003802480 0.009587943 0.014879656 0.1773804280
nokiadisneg 0.9057326378 0.016469336 0.053033076 0.031269453 -0.0007818005
htcdisneg 0.0358414565 0.270474023 0.374707296 0.521369825 0.0827231553
iphonedisunc 0.0050123671 0.052906939 0.299074293 0.028896976 0.0271242781
samsungdisunc 0.0649210676 0.051841658 0.117147742 0.331737722 0.1246994085
sonydisunc -0.0009218353 0.025058938 0.036018255 0.063338287 0.5780401304
nokiadisunc 0.7956709983 0.006690145 0.018880092 0.051899349 -0.0006256755
htcdisunc 0.0163417006 0.386465078 0.160153769 0.163322433 0.0752912506
iphoneperpos 0.0340558067 0.242604866 0.257568960 0.130965178 0.0265814721
samsungperpos 0.0257099089 0.067849952 0.172260776 0.590556431 0.0591163229
sonyperpos -0.0012786647 0.013336985 0.017790709 0.037777680 0.5019700016
nokiaperpos 0.8874498813 0.012832239 0.039337638 0.023510164 -0.0008913832
htcperpos 0.0263959730 0.586175384 0.205400545 0.242173307 0.0227282674
iphoneperneg 0.0307357306 0.074396779 0.308875213 0.259390474 0.0446710591
samsungperneg 0.0262075456 0.133387536 0.361394034 0.825420862 0.0724224540
sonyperneg -0.0006316834 0.003725933 0.020559519 0.025463286 0.4654221318
nokiaperneg 0.8356084723 0.013673289 0.038254106 0.020272467 -0.0009094316
htcperneg 0.0337746618 0.290333302 0.348535462 0.511629134 0.0281019160
iphoneperunc 0.0215513806 0.059577005 0.217579385 0.069828121 0.0266791114
samsungperunc 0.0492523325 0.058155116 0.138709352 0.389305581 0.0847821713
sonyperunc -0.0008020494 0.018080529 0.032569554 0.060836735 0.6040116918
nokiaperunc 0.8582954367 0.010477696 0.026549885 0.036542546 -0.0008231246
htcperunc 0.0172606280 0.253677808 0.114715736 0.122047959 0.0262898504
iosperpos 0.1031232916 -0.006121324 -0.012228970 0.110072741 -0.0012764663
googleperpos 0.0115643182 0.163144592 0.417185277 0.658643639 0.0209042210
iosperneg 0.1035400799 -0.005760507 -0.013641561 0.081293922 -0.0011656709
googleperneg 0.0039406908 0.177229614 0.468074693 0.794281952 0.0251264773
iosperunc 0.1651880784 -0.006078585 -0.010748721 0.047045360 -0.0028646448
googleperunc 0.0125178481 0.100031085 0.241002513 0.342119638 -0.0015319542
iphonesentiment -0.0333745609 -0.120434115 -0.083963139 -0.185988857 -0.0248264033
nokiacamneg htccamneg iphonecamunc samsungcamunc sonycamunc
iphone -0.0091860039 0.104612765 0.750403174 0.07345136 -0.0030644436
samsunggalaxy -0.0009794805 0.222776563 -0.010155099 0.31613435 0.1041234759
sonyxperia -0.0044672329 -0.012284395 -0.007638359 0.05877667 0.3766328700
nokialumina 0.7294341201 0.037255641 0.016237082 0.04092225 -0.0019143276
htcphone 0.0001910834 0.036765276 0.001173998 0.01564383 0.0098429481
ios 0.0046513511 -0.023048787 0.732611711 -0.01239010 -0.0064841085
googleandroid -0.0018238625 0.562702861 0.042955147 0.39143285 -0.0065777411
iphonecampos 0.0268554798 0.206584693 0.473266316 0.07694320 0.0293973265
samsungcampos 0.0143682706 0.295428414 0.028875432 0.81479929 0.0988362178
sonycampos -0.0019377086 0.013568090 0.016442392 0.16404312 0.5284523138
nokiacampos 0.9142720770 0.030501288 0.018636402 0.05803788 -0.0012757645
htccampos 0.0153958195 0.450715453 0.163480446 0.11342051 0.0373285316
iphonecamneg 0.0702425023 0.507638049 0.643460020 0.26266536 0.0340240958
samsungcamneg 0.0154652632 0.661017063 0.061619492 0.70383784 0.0507620794
sonycamneg -0.0008645238 0.038003476 0.025059285 0.12861974 0.6030047959
nokiacamneg 1.0000000000 0.029446019 0.015900446 0.05658335 -0.0013467613
htccamneg 0.0294460192 1.000000000 0.112118301 0.37440485 0.0247482526
iphonecamunc 0.0159004463 0.112118301 1.000000000 0.05614601 0.0473068441
samsungcamunc 0.0565833532 0.374404849 0.056146005 1.00000000 0.2879321571
sonycamunc -0.0013467613 0.024748253 0.047306844 0.28793216 1.0000000000
nokiacamunc 0.8435279350 0.027338344 0.013593577 0.10552249 -0.0011974921
htccamunc 0.0265105501 0.661111712 0.171847066 0.17875318 0.1084644987
iphonedispos 0.0276449718 0.098294710 0.209007616 0.06737529 0.0256779528
samsungdispos 0.0569739542 0.286484665 0.038323930 0.72752834 0.1265611252
sonydispos -0.0010750732 0.020739500 0.012209066 0.10970557 0.4434927247
nokiadispos 0.8112280252 0.025720853 0.015624798 0.14095720 -0.0011372326
htcdispos 0.0078541469 0.135171608 0.023328496 0.05295388 0.0187454585
iphonedisneg 0.0223821976 0.151600245 0.253253711 0.09882361 0.0241162643
samsungdisneg 0.0327538566 0.495228320 0.055065985 0.63429301 0.0976382241
sonydisneg -0.0004530488 0.009023997 0.003641380 0.03090804 0.2388456015
nokiadisneg 0.8693030357 0.031456755 0.016147952 0.10607426 -0.0012178944
htcdisneg 0.0346318727 0.728948508 0.079895368 0.34829348 0.0626007989
iphonedisunc 0.0045177696 0.044419886 0.361321734 0.03967813 0.0306197606
samsungdisunc 0.0634077378 0.168584878 0.032740815 0.55069197 0.1587354458
sonydisunc -0.0009731358 0.037615168 0.030042395 0.19905389 0.7174089400
nokiadisunc 0.7211247686 0.011908284 0.005721107 0.17026170 -0.0009746818
htcdisunc 0.0146507775 0.474559542 0.085983009 0.18840329 0.1073824307
iphoneperpos 0.0312615923 0.160387571 0.190248578 0.09422706 0.0187935025
samsungperpos 0.0249977050 0.246822075 0.027429286 0.76866705 0.0580179791
sonyperpos -0.0013498229 0.012290232 0.009325653 0.09628229 0.3945468871
nokiaperpos 0.8228805584 0.022928192 0.011472100 0.08237079 -0.0013886032
htcperpos 0.0238671607 0.550676429 0.092072136 0.17876940 0.0291620375
iphoneperneg 0.0326173059 0.246452247 0.113175498 0.16484231 0.0148161988
samsungperneg 0.0254366097 0.509565524 0.055070726 0.68441917 0.0507382344
sonyperneg -0.0006668369 0.008808122 0.004866392 0.04595525 0.2071803257
nokiaperneg 0.8322058239 0.025523834 0.009972578 0.07224142 -0.0014167191
htcperneg 0.0318802035 0.756413279 0.070524621 0.32665886 0.0186629297
iphoneperunc 0.0188185221 0.099731103 0.174433158 0.07492203 0.0273592822
samsungperunc 0.0480734420 0.198497720 0.033915160 0.60256883 0.0860877971
sonyperunc -0.0008466839 0.029574377 0.025255729 0.15254243 0.5673580082
nokiaperunc 0.7889271503 0.019517636 0.009049054 0.12318139 -0.0012822694
htcperunc 0.0162339357 0.425360579 0.057397481 0.12451633 0.0319632466
iosperpos 0.0890019113 -0.010934307 -0.004920454 0.12901202 -0.0008902753
googleperpos 0.0027187820 0.578324761 0.076915508 0.41737461 -0.0038250565
iosperneg 0.0903106208 -0.009877889 -0.008705784 0.09735470 -0.0007460493
googleperneg -0.0004450102 0.652644007 0.074858366 0.47668997 -0.0042044682
iosperunc 0.1436761784 -0.010191180 -0.001336459 0.05761233 -0.0044625643
googleperunc 0.0037721473 0.333727389 0.058138669 0.26943151 -0.0023864893
iphonesentiment -0.0330694691 -0.222972178 0.001443485 -0.13804591 -0.0503268537
nokiacamunc htccamunc iphonedispos samsungdispos sonydispos
iphone -0.0086021744 0.026137801 0.0526246212 0.061074202 -0.0038265686
samsunggalaxy 0.0056913189 0.072964497 -0.0065259392 0.281378596 0.0613598274
sonyxperia -0.0039721040 0.014249220 -0.0181210186 0.040062534 0.2525892158
nokialumina 0.6341714578 0.036124092 0.0283164282 0.041455744 -0.0015281417
htcphone 0.0003640555 0.029152495 0.0002525733 0.013145405 0.0069587360
ios 0.0063413897 -0.015784533 0.0143768878 -0.009906467 0.0042066852
googleandroid 0.0003252623 0.166181849 0.0669526940 0.316132023 -0.0016689972
iphonecampos 0.0212773077 0.321523039 0.2725865474 0.060476039 0.0177490834
samsungcampos 0.0283225789 0.104495332 0.0394271339 0.643691775 0.0581222272
sonycampos -0.0017229413 0.056574443 0.0196168049 0.111287385 0.4049930253
nokiacampos 0.9402208771 0.028579684 0.0292070224 0.058410328 -0.0010183988
htccampos 0.0149261095 0.656659442 0.1298129556 0.083526364 0.0220156223
iphonecamneg 0.0372665226 0.238011225 0.2619831418 0.200390891 0.0158907533
samsungcamneg 0.0311313130 0.200439201 0.0793434359 0.545463046 0.0374249243
sonycamneg -0.0007687037 0.036701616 0.0248279099 0.109912659 0.3372117408
nokiacamneg 0.8435279350 0.026510550 0.0276449718 0.056973954 -0.0010750732
htccamneg 0.0273383443 0.661111712 0.0982947096 0.286484665 0.0207394998
iphonecamunc 0.0135935769 0.171847066 0.2090076163 0.038323930 0.0122090661
samsungcamunc 0.1055224889 0.178753184 0.0673752918 0.727528342 0.1097055700
sonycamunc -0.0011974921 0.108464499 0.0256779528 0.126561125 0.4434927247
nokiacamunc 1.0000000000 0.025875134 0.0191518674 0.105900155 -0.0009559167
htccamunc 0.0258751340 1.000000000 0.0938897063 0.123506894 0.0377995521
iphonedispos 0.0191518674 0.093889706 1.0000000000 0.150378945 0.0236098053
samsungdispos 0.1059001549 0.123506894 0.1503789449 1.000000000 0.1019646067
sonydispos -0.0009559167 0.037799552 0.0236098053 0.101964607 1.0000000000
nokiadispos 0.8836456594 0.024518076 0.0344991383 0.141338260 -0.0009078136
htcdispos 0.0077391682 0.144467590 0.0421029911 0.100039517 0.0158319967
iphonedisneg 0.0150392199 0.067470212 0.8687653874 0.165537970 0.0154532548
samsungdisneg 0.0621701347 0.177177041 0.1635405432 0.864664985 0.0744018028
sonydisneg -0.0004028348 0.009773739 0.0049575187 0.027185858 0.8972867887
nokiadisneg 0.9041130819 0.028970936 0.0339114154 0.106457674 -0.0009722031
htcdisneg 0.0329913833 0.489481843 0.1639872192 0.533151090 0.0530167286
iphonedisunc 0.0034092367 0.058927289 0.8830262288 0.129786033 0.0126801713
samsungdisunc 0.1167982852 0.103691952 0.1611670483 0.909832061 0.0874805088
sonydisunc -0.0008652776 0.074237080 0.0272975223 0.126536531 0.7730887035
nokiadisunc 0.9121141739 0.011894442 0.0095633363 0.170615493 -0.0007780549
htcdisunc 0.0148406494 0.605687511 0.1718221450 0.460725918 0.0574162246
iphoneperpos 0.0222404059 0.157350739 0.6593538274 0.174837536 0.0101954743
samsungperpos 0.0474844688 0.097082536 0.0927026672 0.816118726 0.0393349408
sonyperpos -0.0012002143 0.026428434 0.0117148037 0.075502889 0.5024874205
nokiaperpos 0.9027653299 0.024826942 0.0248343768 0.082786740 -0.0011084740
htcperpos 0.0263996540 0.652254312 0.1252579817 0.276489557 0.0198549806
iphoneperneg 0.0216551399 0.108741499 0.6377684302 0.237293893 0.0057365246
samsungperneg 0.0488933545 0.174304894 0.1420730151 0.808058427 0.0369525459
sonyperneg -0.0005929276 0.009450643 0.0047438599 0.038757327 0.1683775861
nokiaperneg 0.8633797378 0.026924854 0.0189662661 0.072659307 -0.0011309180
htcperneg 0.0344217184 0.559357663 0.1239851159 0.435057442 0.0165139802
iphoneperunc 0.0166053058 0.113207080 0.6652375226 0.208169963 0.0137922154
samsungperunc 0.0889446222 0.108102559 0.1574463233 0.898380776 0.0542203186
sonyperunc -0.0007528410 0.050625072 0.0276806457 0.111113002 0.3407659807
nokiaperunc 0.9581520620 0.018802218 0.0123818671 0.123591394 -0.0010235915
htcperunc 0.0159489558 0.601513451 0.0918953795 0.285206316 0.0194072718
iosperpos 0.1084241245 -0.007866478 0.0202320633 0.118107288 0.0253918473
googleperpos 0.0059091363 0.223305123 0.1655756249 0.606458035 0.0001583647
iosperneg 0.1088977055 -0.007102265 0.0152927176 0.092014413 0.0248326306
googleperneg 0.0012988106 0.227576803 0.1470225674 0.579951480 0.0017093490
iosperunc 0.1735035602 -0.005186414 0.0247667616 0.057287597 -0.0035623113
googleperunc 0.0068285408 0.162430756 0.1796863033 0.636103149 -0.0019050522
iphonesentiment -0.0315497295 -0.148881468 0.0145468235 -0.099262059 -0.0386353028
nokiadispos htcdispos iphonedisneg samsungdisneg sonydisneg
iphone -0.0082021539 0.0071249159 0.175572621 0.111821338 -0.0027774491
samsunggalaxy 0.0102477757 0.0248386343 0.017824130 0.304385446 0.0067858231
sonyxperia -0.0037722221 0.0032991048 -0.013589598 0.007706073 0.1632854243
nokialumina 0.6502528013 0.0105537205 0.023741675 0.022910189 -0.0006439773
htcphone 0.0003111175 0.9775380039 0.002796301 0.020154247 0.0030563250
ios 0.0030652805 -0.0057487757 0.113783629 -0.011705958 0.0080627604
googleandroid -0.0041735324 0.0575517863 0.121820615 0.542439640 0.0002154346
iphonecampos 0.0263172760 0.0674289905 0.148650674 0.089812938 0.0028844028
samsungcampos 0.0383707155 0.0329234763 0.065278833 0.487871125 0.0112361693
sonycampos -0.0016362405 0.0164571512 0.006716763 0.058932439 0.1318919118
nokiacampos 0.8708585691 0.0088485247 0.022170003 0.033683217 -0.0004291655
htccampos 0.0146291869 0.1404469728 0.041086089 0.131056692 0.0038024800
iphonecamneg 0.0500131699 0.0554395800 0.346878956 0.350114204 0.0095879433
samsungcamneg 0.0423910836 0.0655959978 0.152069590 0.755771365 0.0148796562
sonycamneg -0.0007300214 0.0151478630 0.040038521 0.119973001 0.1773804280
nokiacamneg 0.8112280252 0.0078541469 0.022382198 0.032753857 -0.0004530488
htccamneg 0.0257208533 0.1351716081 0.151600245 0.495228320 0.0090239969
iphonecamunc 0.0156247976 0.0233284957 0.253253711 0.055065985 0.0036413799
samsungcamunc 0.1409571952 0.0529538787 0.098823606 0.634293006 0.0309080398
sonycamunc -0.0011372326 0.0187454585 0.024116264 0.097638224 0.2388456015
nokiacamunc 0.8836456594 0.0077391682 0.015039220 0.062170135 -0.0004028348
htccamunc 0.0245180762 0.1444675899 0.067470212 0.177177041 0.0097737393
iphonedispos 0.0344991383 0.0421029911 0.868765387 0.163540543 0.0049575187
samsungdispos 0.1413382600 0.1000395171 0.165537970 0.864664985 0.0271858576
sonydispos -0.0009078136 0.0158319967 0.015453255 0.074401803 0.8972867887
nokiadispos 1.0000000000 0.0075947659 0.026055893 0.083429617 -0.0003825636
htcdispos 0.0075947659 1.0000000000 0.034742979 0.117006323 0.0041258099
iphonedisneg 0.0260558932 0.0347429788 1.000000000 0.215344041 0.0086647820
samsungdisneg 0.0834296171 0.1170063231 0.215344041 1.000000000 0.0324996878
sonydisneg -0.0003825636 0.0041258099 0.008664782 0.032499688 1.0000000000
nokiadisneg 0.9642125180 0.0087071316 0.027487686 0.062483517 -0.0004096981
htcdisneg 0.0313410172 0.1804130745 0.222763351 0.695800085 0.0251869341
iphonedisunc 0.0055634233 0.0309291882 0.879950578 0.136595813 0.0048074081
samsungdisunc 0.1555088687 0.1089989653 0.170649469 0.818110172 0.0311061389
sonydisunc -0.0008217356 0.0196386582 0.030450206 0.123078962 0.6588319145
nokiadisunc 0.8846581356 0.0034865140 0.007260959 0.101104482 -0.0003278817
htcdisunc 0.0140462214 0.2018521118 0.158725895 0.500968511 0.0200940302
iphoneperpos 0.0374559878 0.0537746528 0.530888336 0.215372074 0.0014505894
samsungperpos 0.0637346396 0.0647210892 0.116563641 0.707605701 0.0121258783
sonyperpos -0.0011398179 0.0089685103 0.008028103 0.064069024 0.3702542519
nokiaperpos 0.8594816669 0.0070503649 0.018659378 0.048154434 -0.0004671243
htcperpos 0.0239161992 0.1709799708 0.100581679 0.346537661 0.0055861443
iphoneperneg 0.0313060407 0.0468734959 0.640995104 0.319865181 0.0027343448
samsungperneg 0.0658243628 0.0999581223 0.195391018 0.939467262 0.0142097172
sonyperneg -0.0005630906 0.0041425495 0.007229347 0.040938292 0.1075178973
nokiaperneg 0.7603520617 0.0075095629 0.015317418 0.042068185 -0.0004765825
htcperneg 0.0305980536 0.1555950160 0.173659920 0.592740421 0.0071159432
iphoneperunc 0.0182744228 0.0453585748 0.570044418 0.224776555 0.0035375194
samsungperunc 0.1185634253 0.1056443543 0.170623380 0.817377205 0.0193882137
sonyperunc -0.0007149570 0.0154512162 0.023878172 0.108931613 0.1126326681
nokiaperunc 0.8367002787 0.0053168953 0.009722761 0.072669807 -0.0004313538
htcperunc 0.0144895062 0.1354950113 0.096513956 0.317064822 0.0066827986
iosperpos 0.0795411340 -0.0011472646 0.015557280 0.104504376 0.0302728027
googleperpos -0.0024269726 0.1183397028 0.218540632 0.808752967 0.0005795463
iosperneg 0.0794048652 -0.0010128631 0.016862912 0.081942133 0.0295314983
googleperneg -0.0026677068 0.1092388830 0.213640441 0.826603931 0.0019065213
iosperunc 0.1272636476 0.0005786204 0.018221646 0.050729608 -0.0015012009
googleperunc -0.0015142114 0.1240182192 0.204416264 0.735526147 -0.0008028119
iphonesentiment -0.0259223780 -0.0604057929 0.003144905 -0.139964721 -0.0199561100
nokiadisneg htcdisneg iphonedisunc samsungdisunc sonydisunc
iphone -0.0087896514 0.0852733380 0.250929821 0.038726564 -0.0045529578
samsunggalaxy 0.0056401787 0.1888214611 -0.027879224 0.190038399 0.0605561472
sonyxperia -0.0040397789 -0.0021376810 -0.017980754 0.026313761 0.2954284939
nokialumina 0.6922675788 0.0442224554 0.002681337 0.046896099 -0.0013832449
htcphone 0.0003885495 0.0376533014 -0.002108389 0.009413329 0.0052678396
ios 0.0034323575 -0.0197092424 0.218834874 -0.005950864 0.0006261928
googleandroid -0.0044695534 0.4470127937 0.017791369 0.188924348 -0.0047529101
iphonecampos 0.0263065715 0.1101016903 0.188310035 0.035791405 0.0194031753
samsungcampos 0.0284542424 0.2384253937 0.012312670 0.389689453 0.0676677209
sonycampos -0.0017522960 0.0376238338 0.007383581 0.089488968 0.3888036304
nokiacampos 0.9057326378 0.0358414565 0.005012367 0.064921068 -0.0009218353
htccampos 0.0164693360 0.2704740233 0.052906939 0.051841658 0.0250589384
iphonecamneg 0.0530330760 0.3747072961 0.299074293 0.117147742 0.0360182554
samsungcamneg 0.0312694532 0.5213698250 0.028896976 0.331737722 0.0633382871
sonycamneg -0.0007818005 0.0827231553 0.027124278 0.124699409 0.5780401304
nokiacamneg 0.8693030357 0.0346318727 0.004517770 0.063407738 -0.0009731358
htccamneg 0.0314567550 0.7289485078 0.044419886 0.168584878 0.0376151684
iphonecamunc 0.0161479520 0.0798953676 0.361321734 0.032740815 0.0300423951
samsungcamunc 0.1060742589 0.3482934774 0.039678126 0.550691969 0.1990538876
sonycamunc -0.0012178944 0.0626007989 0.030619761 0.158735446 0.7174089400
nokiacamunc 0.9041130819 0.0329913833 0.003409237 0.116798285 -0.0008652776
htccamunc 0.0289709356 0.4894818428 0.058927289 0.103691952 0.0742370804
iphonedispos 0.0339114154 0.1639872192 0.883026229 0.161167048 0.0272975223
samsungdispos 0.1064576742 0.5331510902 0.129786033 0.909832061 0.1265365313
sonydispos -0.0009722031 0.0530167286 0.012680171 0.087480509 0.7730887035
nokiadispos 0.9642125180 0.0313410172 0.005563423 0.155508869 -0.0008217356
htcdispos 0.0087071316 0.1804130745 0.030929188 0.108998965 0.0196386582
iphonedisneg 0.0274876862 0.2227633513 0.879950578 0.170649469 0.0304502061
samsungdisneg 0.0624835172 0.6958000848 0.136595813 0.818110172 0.1230789623
sonydisneg -0.0004096981 0.0251869341 0.004807408 0.031106139 0.6588319145
nokiadisneg 1.0000000000 0.0383347075 0.005544196 0.117424630 -0.0008800198
htcdisneg 0.0383347075 1.0000000000 0.136125810 0.538530803 0.0867272010
iphonedisunc 0.0055441959 0.1361258096 1.000000000 0.165538393 0.0376336503
samsungdisunc 0.1174246298 0.5385308025 0.165538393 1.000000000 0.1820790584
sonydisunc -0.0008800198 0.0867272010 0.037633650 0.182079058 1.0000000000
nokiadisunc 0.8660901242 0.0149516316 0.001110546 0.187398068 -0.0007042805
htcdisunc 0.0165353241 0.7846720113 0.170131836 0.569447354 0.1276401084
iphoneperpos 0.0371693201 0.2041175256 0.554364879 0.188295133 0.0144778088
samsungperpos 0.0477234412 0.3706617924 0.079438177 0.676382710 0.0546811048
sonyperpos -0.0012206630 0.0339514148 0.005151596 0.072158885 0.4319240195
nokiaperpos 0.8791736521 0.0299734535 0.002340012 0.091673805 -0.0010033697
htcperpos 0.0280713663 0.5757290234 0.084321539 0.290911699 0.0300892147
iphoneperneg 0.0334073208 0.3033383674 0.564479458 0.231336930 0.0118804562
samsungperneg 0.0491333409 0.6212857650 0.111568445 0.714524694 0.0570781706
sonyperneg -0.0006030296 0.0232962762 0.002926026 0.040748408 0.1845288613
nokiaperneg 0.8213352685 0.0324488526 0.001492592 0.080620019 -0.0010236856
htcperneg 0.0365017241 0.8428682456 0.095449680 0.416547226 0.0282706573
iphoneperunc 0.0192250179 0.2236255729 0.623929443 0.253310087 0.0246677278
samsungperunc 0.0894173232 0.5336743572 0.156926656 0.940304299 0.0918810680
sonyperunc -0.0007656676 0.0682515586 0.022878057 0.129397099 0.4765973052
nokiaperunc 0.8618167419 0.0235691136 0.001485287 0.136216491 -0.0009265356
htcperunc 0.0176389479 0.5497638190 0.092742570 0.344839418 0.0370091903
iosperpos 0.0871799820 0.0002582922 0.024055145 0.078622929 0.0145998730
googleperpos -0.0025991133 0.7041173806 0.132862181 0.594372080 -0.0027638895
iosperneg 0.0869862824 0.0010729562 0.023660497 0.063341303 0.0143102866
googleperneg -0.0028569223 0.6983625307 0.106083576 0.512731901 -0.0030380429
iosperunc 0.1394095914 0.0098165195 0.030107042 0.039950863 -0.0032245366
googleperunc -0.0016216116 0.6431743675 0.172276045 0.738456505 -0.0017244171
iphonesentiment -0.0287585883 -0.1927272667 0.027172723 -0.059548267 -0.0321371543
nokiadisunc htcdisunc iphoneperpos samsungperpos sonyperpos
iphone -0.00758808020 0.024321607 -0.0095076663 0.051538330 -0.0063266804
samsunggalaxy 0.01466082095 0.071745603 -0.0031694293 0.242866387 0.0674892485
sonyxperia -0.00323303793 0.010002504 -0.0287170338 0.020914013 0.2661417156
nokialumina 0.49133177525 0.021114387 0.0333454788 0.017459058 -0.0019186794
htcphone -0.00006612816 0.029195313 0.0001213601 0.009710561 0.0048119185
ios 0.00611016542 -0.012652164 -0.0219530895 -0.002130839 -0.0040906577
googleandroid -0.00357698676 0.147068090 0.1060606249 0.270354937 0.0008356533
iphonecampos 0.00960830397 0.156063063 0.3483324156 0.045221267 0.0139443738
samsungcampos 0.04681151761 0.086766462 0.0562722587 0.793898531 0.0473952698
sonycampos -0.00140236373 0.055055469 0.0091522569 0.046922592 0.3873108356
nokiacampos 0.79567099835 0.016341701 0.0340558067 0.025709909 -0.0012786647
htccampos 0.00669014486 0.386465078 0.2426048659 0.067849952 0.0133369850
iphonecamneg 0.01888009160 0.160153769 0.2575689601 0.172260776 0.0177907090
samsungcamneg 0.05189934943 0.163322433 0.1309651776 0.590556431 0.0377776797
sonycamneg -0.00062567549 0.075291251 0.0265814721 0.059116323 0.5019700016
nokiacamneg 0.72112476857 0.014650777 0.0312615923 0.024997705 -0.0013498229
htccamneg 0.01190828438 0.474559542 0.1603875714 0.246822075 0.0122902322
iphonecamunc 0.00572110731 0.085983009 0.1902485783 0.027429286 0.0093256533
samsungcamunc 0.17026170473 0.188403288 0.0942270564 0.768667045 0.0962822917
sonycamunc -0.00097468176 0.107382431 0.0187935025 0.058017979 0.3945468871
nokiacamunc 0.91211417395 0.014840649 0.0222404059 0.047484469 -0.0012002143
htccamunc 0.01189444231 0.605687511 0.1573507388 0.097082536 0.0264284339
iphonedispos 0.00956333630 0.171822145 0.6593538274 0.092702667 0.0117148037
samsungdispos 0.17061549326 0.460725918 0.1748375362 0.816118726 0.0755028891
sonydispos -0.00077805486 0.057416225 0.0101954743 0.039334941 0.5024874205
nokiadispos 0.88465813560 0.014046221 0.0374559878 0.063734640 -0.0011398179
htcdispos 0.00348651401 0.201852112 0.0537746528 0.064721089 0.0089685103
iphonedisneg 0.00726095901 0.158725895 0.5308883356 0.116563641 0.0080281030
samsungdisneg 0.10110448185 0.500968511 0.2153720744 0.707605701 0.0640690240
sonydisneg -0.00032788169 0.020094030 0.0014505894 0.012125878 0.3702542519
nokiadisneg 0.86609012417 0.016535324 0.0371693201 0.047723441 -0.0012206630
htcdisneg 0.01495163164 0.784672011 0.2041175256 0.370661792 0.0339514148
iphonedisunc 0.00111054627 0.170131836 0.5543648794 0.079438177 0.0051515957
samsungdisunc 0.18739806770 0.569447354 0.1882951326 0.676382710 0.0721588855
sonydisunc -0.00070428051 0.127640108 0.0144778088 0.054681105 0.4319240195
nokiadisunc 1.00000000000 0.006625724 0.0104387347 0.077247830 -0.0009768975
htcdisunc 0.00662572418 1.000000000 0.2039435251 0.288714036 0.0395562543
iphoneperpos 0.01043873467 0.203943525 1.0000000000 0.140785232 0.0303379013
samsungperpos 0.07724782973 0.288714036 0.1407852324 1.000000000 0.0679568359
sonyperpos -0.00097689750 0.039556254 0.0303379013 0.067956836 1.0000000000
nokiaperpos 0.81559766722 0.015096830 0.0287020602 0.036767204 -0.0013917599
htcperpos 0.01294025652 0.686133766 0.2075381660 0.200799111 0.0331398411
iphoneperneg 0.01051732897 0.201737692 0.7948324525 0.188500749 0.0289067106
samsungperneg 0.07995124488 0.405688534 0.2114849129 0.802014412 0.0447320903
sonyperneg -0.00048260502 0.020092101 0.0184788426 0.024476283 0.7985168799
nokiaperneg 0.76244382942 0.016102467 0.0215850635 0.032114751 -0.0014199397
htcperneg 0.01662565518 0.677325871 0.1826860036 0.323342889 0.0101492440
iphoneperunc 0.00797387608 0.246904143 0.7918276302 0.140337688 0.0197639928
samsungperunc 0.14299747815 0.538856907 0.1989680382 0.777217462 0.0536779030
sonyperunc -0.00061276434 0.083274559 0.0363795828 0.057896426 0.7358017934
nokiaperunc 0.92393424655 0.010654634 0.0152806435 0.055507074 -0.0012851844
htcperunc 0.00732604634 0.721406551 0.1233900172 0.189564961 0.0140733766
iosperpos 0.10203694492 0.006433213 0.2103426005 0.274209204 0.0057578219
googleperpos -0.00208007219 0.483030041 0.2402666517 0.444302472 0.0077119343
iosperneg 0.10201208187 0.006751633 0.2246503851 0.214228347 0.0057305728
googleperneg -0.00228639695 0.406568606 0.2188475265 0.441229070 0.0080695911
iosperunc 0.16268983125 0.019676511 0.2118092692 0.137056666 -0.0044727090
googleperunc -0.00129777694 0.593493504 0.2376254310 0.427542257 -0.0023919145
iphonesentiment -0.02397198837 -0.132952797 0.0296378999 -0.081063185 -0.0389127438
nokiaperpos htcperpos iphoneperneg samsungperneg sonyperneg
iphone -0.0105089285 0.0306212796 0.013863107 0.115130047 -0.00362474402
samsunggalaxy 0.0018461920 0.0882886778 0.045962586 0.303559905 0.00997679864
sonyxperia -0.0046060231 0.0046768178 -0.028774205 -0.001931200 0.12240670885
nokialumina 0.7374571504 0.0391126464 0.033735414 0.017354031 -0.00094786229
htcphone 0.0004544852 0.0309092171 0.004284747 0.017457472 0.00111336490
ios 0.0022605934 -0.0181673563 -0.012566493 -0.007167963 -0.00290237602
googleandroid -0.0022999416 0.2094141916 0.212525142 0.558089939 0.00565657376
iphonecampos 0.0211775527 0.2870846550 0.151918629 0.092030029 0.00703403006
samsungcampos 0.0215811648 0.1151318489 0.112507527 0.546669519 0.01936569878
sonycampos -0.0019979103 0.0213259276 0.006280325 0.034148912 0.18282943494
nokiacampos 0.8874498813 0.0263959730 0.030735731 0.026207546 -0.00063168344
htccampos 0.0128322395 0.5861753843 0.074396779 0.133387536 0.00372593318
iphonecamneg 0.0393376378 0.2054005445 0.308875213 0.361394034 0.02055951914
samsungcamneg 0.0235101641 0.2421733069 0.259390474 0.825420862 0.02546328560
sonycamneg -0.0008913832 0.0227282674 0.044671059 0.072422454 0.46542213179
nokiacamneg 0.8228805584 0.0238671607 0.032617306 0.025436610 -0.00066683691
htccamneg 0.0229281922 0.5506764295 0.246452247 0.509565524 0.00880812225
iphonecamunc 0.0114721001 0.0920721357 0.113175498 0.055070726 0.00486639184
samsungcamunc 0.0823707914 0.1787694006 0.164842312 0.684419168 0.04595524506
sonycamunc -0.0013886032 0.0291620375 0.014816199 0.050738234 0.20718032566
nokiacamunc 0.9027653299 0.0263996540 0.021655140 0.048893354 -0.00059292756
htccamunc 0.0248269423 0.6522543124 0.108741499 0.174304894 0.00945064349
iphonedispos 0.0248343768 0.1252579817 0.637768430 0.142073015 0.00474385985
samsungdispos 0.0827867404 0.2764895568 0.237293893 0.808058427 0.03875732713
sonydispos -0.0011084740 0.0198549806 0.005736525 0.036952546 0.16837758606
nokiadispos 0.8594816669 0.0239161992 0.031306041 0.065824363 -0.00056309061
htcdispos 0.0070503649 0.1709799708 0.046873496 0.099958122 0.00414254948
iphonedisneg 0.0186593778 0.1005816794 0.640995104 0.195391018 0.00722934657
samsungdisneg 0.0481544338 0.3465376613 0.319865181 0.939467262 0.04093829236
sonydisneg -0.0004671243 0.0055861443 0.002734345 0.014209717 0.10751789732
nokiadisneg 0.8791736521 0.0280713663 0.033407321 0.049133341 -0.00060302960
htcdisneg 0.0299734535 0.5757290234 0.303338367 0.621285765 0.02329627618
iphonedisunc 0.0023400120 0.0843215394 0.564479458 0.111568445 0.00292602611
samsungdisunc 0.0916738052 0.2909116988 0.231336930 0.714524694 0.04074840761
sonydisunc -0.0010033697 0.0300892147 0.011880456 0.057078171 0.18452886125
nokiadisunc 0.8155976672 0.0129402565 0.010517329 0.079951245 -0.00048260502
htcdisunc 0.0150968302 0.6861337658 0.201737692 0.405688534 0.02009210094
iphoneperpos 0.0287020602 0.2075381660 0.794832452 0.211484913 0.01847884261
samsungperpos 0.0367672042 0.2007991114 0.188500749 0.802014412 0.02447628284
sonyperpos -0.0013917599 0.0331398411 0.028906711 0.044732090 0.79851687987
nokiaperpos 1.0000000000 0.0346286812 0.023873403 0.037663085 -0.00068755452
htcperpos 0.0346286812 1.0000000000 0.160466806 0.316889412 0.00594937209
iphoneperneg 0.0238734028 0.1604668060 1.000000000 0.316338873 0.04785233669
samsungperneg 0.0376630853 0.3168894124 0.316338873 1.000000000 0.03156948075
sonyperneg -0.0006875545 0.0059493721 0.047852337 0.031569481 1.00000000000
nokiaperneg 0.9570143813 0.0370129904 0.021121718 0.032811115 -0.00070147587
htcperneg 0.0445128708 0.7154529254 0.292967979 0.561158754 0.00800541298
iphoneperunc 0.0143537817 0.1418425513 0.759483720 0.198159549 0.01557892768
samsungperunc 0.0696745358 0.2994474743 0.246448012 0.776166450 0.03049156461
sonyperunc -0.0008729890 0.0260758379 0.042156459 0.060809143 0.66801812499
nokiaperunc 0.9173333678 0.0205526875 0.015346801 0.057203676 -0.00063490432
htcperunc 0.0163730197 0.8497387456 0.140183947 0.271244509 0.00629471284
iosperpos 0.0849480995 -0.0028025082 0.247457091 0.202892247 0.00003962787
googleperpos 0.0020510756 0.3802776224 0.345246653 0.758411098 0.01053912948
iosperneg 0.0845291429 -0.0027668119 0.282778869 0.161560499 0.00009862815
googleperneg -0.0008238620 0.3584582984 0.348685318 0.796365113 0.01214047990
iosperunc 0.1359424951 -0.0001889917 0.255735698 0.103157774 -0.00220959905
googleperunc 0.0031408747 0.3683266512 0.296226849 0.641228695 -0.00118164898
iphonesentiment -0.0415946125 -0.1784270382 -0.004804058 -0.138656977 -0.03085009026
nokiaperneg htcperneg iphoneperunc samsungperunc sonyperunc
iphone -0.0107809387 0.0759754478 -0.0160374243 0.046821536 -0.0030454006
samsunggalaxy 0.0004813798 0.1784097437 -0.0173890375 0.184775057 0.0374818698
sonyxperia -0.0046992842 -0.0120827582 -0.0282204763 0.008007867 0.1516751025
nokialumina 0.7364531206 0.0500508027 0.0201971628 0.035274122 -0.0012035022
htcphone 0.0004623923 0.0339417823 0.0001941898 0.010643554 0.0050176998
ios 0.0023215759 -0.0215760696 -0.0154819150 -0.004770347 -0.0048317142
googleandroid -0.0032259170 0.4334113667 0.0566763832 0.221725967 -0.0041353037
iphonecampos 0.0179871949 0.1093915747 0.1872596205 0.040154370 0.0199870203
samsungcampos 0.0186961477 0.2311715237 0.0318446754 0.487766617 0.0578600356
sonycampos -0.0020383632 0.0090133571 0.0081761787 0.053436363 0.3788118033
nokiacampos 0.8356084723 0.0337746618 0.0215513806 0.049252332 -0.0008020494
htccampos 0.0136732890 0.2903333016 0.0595770054 0.058155116 0.0180805293
iphonecamneg 0.0382541065 0.3485354617 0.2175793853 0.138709352 0.0325695539
samsungcamneg 0.0202724666 0.5116291338 0.0698281207 0.389305581 0.0608367349
sonycamneg -0.0009094316 0.0281019160 0.0266791114 0.084782171 0.6040116918
nokiacamneg 0.8322058239 0.0318802035 0.0188185221 0.048073442 -0.0008466839
htccamneg 0.0255238343 0.7564132793 0.0997311031 0.198497720 0.0295743766
iphonecamunc 0.0099725779 0.0705246210 0.1744331577 0.033915160 0.0252557290
samsungcamunc 0.0722414229 0.3266588581 0.0749220256 0.602568833 0.1525424290
sonycamunc -0.0014167191 0.0186629297 0.0273592822 0.086087797 0.5673580082
nokiacamunc 0.8633797378 0.0344217184 0.0166053058 0.088944622 -0.0007528410
htccamunc 0.0269248539 0.5593576634 0.1132070796 0.108102559 0.0506250723
iphonedispos 0.0189662661 0.1239851159 0.6652375226 0.157446323 0.0276806457
samsungdispos 0.0726593072 0.4350574418 0.2081699628 0.898380776 0.1111130019
sonydispos -0.0011309180 0.0165139802 0.0137922154 0.054220319 0.3407659807
nokiadispos 0.7603520617 0.0305980536 0.0182744228 0.118563425 -0.0007149570
htcdispos 0.0075095629 0.1555950160 0.0453585748 0.105644354 0.0154512162
iphonedisneg 0.0153174176 0.1736599204 0.5700444184 0.170623380 0.0238781723
samsungdisneg 0.0420681850 0.5927404206 0.2247765549 0.817377205 0.1089316128
sonydisneg -0.0004765825 0.0071159432 0.0035375194 0.019388214 0.1126326681
nokiadisneg 0.8213352685 0.0365017241 0.0192250179 0.089417323 -0.0007656676
htcdisneg 0.0324488526 0.8428682456 0.2236255729 0.533674357 0.0682515586
iphonedisunc 0.0014925916 0.0954496805 0.6239294429 0.156926656 0.0228780568
samsungdisunc 0.0806200191 0.4165472257 0.2533100868 0.940304299 0.1293970992
sonydisunc -0.0010236856 0.0282706573 0.0246677278 0.091881068 0.4765973052
nokiadisunc 0.7624438294 0.0166256552 0.0079738761 0.142997478 -0.0006127643
htcdisunc 0.0161024671 0.6773258712 0.2469041428 0.538856907 0.0832745588
iphoneperpos 0.0215850635 0.1826860036 0.7918276302 0.198968038 0.0363795828
samsungperpos 0.0321147508 0.3233428894 0.1403376879 0.777217462 0.0578964261
sonyperpos -0.0014199397 0.0101492440 0.0197639928 0.053677903 0.7358017934
nokiaperpos 0.9570143813 0.0445128708 0.0143537817 0.069674536 -0.0008729890
htcperpos 0.0370129904 0.7154529254 0.1418425513 0.299447474 0.0260758379
iphoneperneg 0.0211217177 0.2929679793 0.7594837197 0.246448012 0.0421564591
samsungperneg 0.0328111151 0.5611587544 0.1981595487 0.776166450 0.0608091432
sonyperneg -0.0007014759 0.0080054130 0.0155789277 0.030491565 0.6680181250
nokiaperneg 1.0000000000 0.0489366503 0.0126138157 0.061213567 -0.0008906650
htcperneg 0.0489366503 1.0000000000 0.1846862477 0.436321786 0.0217050252
iphoneperunc 0.0126138157 0.1846862477 1.0000000000 0.256577185 0.0506531465
samsungperunc 0.0612135669 0.4363217855 0.2565771848 1.000000000 0.0919282907
sonyperunc -0.0008906650 0.0217050252 0.0506531465 0.091928291 1.0000000000
nokiaperunc 0.9052217614 0.0268139759 0.0125533395 0.103766994 -0.0008061390
htcperunc 0.0177330605 0.6596521039 0.1714356260 0.346705088 0.0332332811
iosperpos 0.0795534757 -0.0035898540 0.1666604871 0.102804453 -0.0028611203
googleperpos 0.0005154827 0.6288764765 0.2427354166 0.616441880 -0.0024047420
iosperneg 0.0798194109 -0.0025243537 0.1794111180 0.083217701 -0.0027109919
googleperneg -0.0016059114 0.6389410325 0.1962538259 0.541503979 -0.0026432711
iosperunc 0.1280016003 0.0003615931 0.1817828791 0.053897313 -0.0028055314
googleperunc 0.0016351213 0.5399024601 0.2971400100 0.739887460 -0.0015003415
iphonesentiment -0.0442193857 -0.2091960459 0.0371998590 -0.057919616 -0.0180840317
nokiaperunc htcperunc iosperpos googleperpos iosperneg
iphone -0.0097041964 0.0114142610 -0.02005936292 0.1180083451 -0.01908109981
samsunggalaxy 0.0073052108 0.0449278125 -0.00580167992 0.2460460932 -0.00783935266
sonyxperia -0.0042533121 -0.0048880488 -0.01100923870 -0.0084673071 -0.01032271041
nokialumina 0.6484414145 0.0237567173 0.03071886688 0.0065145374 0.03272091854
htcphone 0.0001122105 0.0214481452 -0.00292694652 0.0191864739 -0.00275835644
ios 0.0050302440 -0.0119295874 0.11827832713 -0.0164015981 0.11232976837
googleandroid -0.0014066039 0.1096851420 -0.01670167255 0.6385807446 -0.01582530404
iphonecampos 0.0148265304 0.0672830706 -0.00399107592 0.1179019014 -0.00705983991
samsungcampos 0.0331966501 0.0613038312 0.10247144375 0.2982813037 0.07569483564
sonycampos -0.0018449182 0.0157814464 -0.00311824554 0.0066726659 -0.00286326790
nokiacampos 0.8582954367 0.0172606280 0.10312329162 0.0115643182 0.10354007985
htccampos 0.0104776962 0.2536778076 -0.00612132405 0.1631445917 -0.00576050726
iphonecamneg 0.0265498854 0.1147157357 -0.01222897038 0.4171852771 -0.01364156129
samsungcamneg 0.0365425460 0.1220479586 0.11007274083 0.6586436387 0.08129392210
sonycamneg -0.0008231246 0.0262898504 -0.00127646634 0.0209042210 -0.00116567094
nokiacamneg 0.7889271503 0.0162339357 0.08900191126 0.0027187820 0.09031062083
htccamneg 0.0195176360 0.4253605788 -0.01093430728 0.5783247613 -0.00987788929
iphonecamunc 0.0090490537 0.0573974810 -0.00492045432 0.0769155084 -0.00870578401
samsungcamunc 0.1231813884 0.1245163314 0.12901201588 0.4173746107 0.09735469825
sonycamunc -0.0012822694 0.0319632466 -0.00089027529 -0.0038250565 -0.00074604928
nokiacamunc 0.9581520620 0.0159489558 0.10842412454 0.0059091363 0.10889770548
htccamunc 0.0188022181 0.6015134514 -0.00786647833 0.2233051228 -0.00710226523
iphonedispos 0.0123818671 0.0918953795 0.02023206325 0.1655756249 0.01529271756
samsungdispos 0.1235913936 0.2852063164 0.11810728841 0.6064580352 0.09201441256
sonydispos -0.0010235915 0.0194072718 0.02539184732 0.0001583647 0.02483263064
nokiadispos 0.8367002787 0.0144895062 0.07954113402 -0.0024269726 0.07940486523
htcdispos 0.0053168953 0.1354950113 -0.00114726457 0.1183397028 -0.00101286315
iphonedisneg 0.0097227609 0.0965139559 0.01555728044 0.2185406324 0.01686291204
samsungdisneg 0.0726698071 0.3170648217 0.10450437637 0.8087529668 0.08194213280
sonydisneg -0.0004313538 0.0066827986 0.03027280271 0.0005795463 0.02953149833
nokiadisneg 0.8618167419 0.0176389479 0.08717998196 -0.0025991133 0.08698628241
htcdisneg 0.0235691136 0.5497638190 0.00025829219 0.7041173806 0.00107295615
iphonedisunc 0.0014852868 0.0927425695 0.02405514497 0.1328621807 0.02366049737
samsungdisunc 0.1362164906 0.3448394176 0.07862292911 0.5943720796 0.06334130276
sonydisunc -0.0009265356 0.0370091903 0.01459987302 -0.0027638895 0.01431028661
nokiadisunc 0.9239342466 0.0073260463 0.10203694492 -0.0020800722 0.10201208187
htcdisunc 0.0106546343 0.7214065507 0.00643321299 0.4830300411 0.00675163323
iphoneperpos 0.0152806435 0.1233900172 0.21034260049 0.2402666517 0.22465038514
samsungperpos 0.0555070737 0.1895649611 0.27420920373 0.4443024721 0.21422834663
sonyperpos -0.0012851844 0.0140733766 0.00575782189 0.0077119343 0.00573057278
nokiaperpos 0.9173333678 0.0163730197 0.08494809951 0.0020510756 0.08452914286
htcperpos 0.0205526875 0.8497387456 -0.00280250819 0.3802776224 -0.00276681187
iphoneperneg 0.0153468013 0.1401839465 0.24745709131 0.3452466533 0.28277886897
samsungperneg 0.0572036762 0.2712445087 0.20289224705 0.7584110978 0.16156049890
sonyperneg -0.0006349043 0.0062947128 0.00003962787 0.0105391295 0.00009862815
nokiaperneg 0.9052217614 0.0177330605 0.07955347571 0.0005154827 0.07981941094
htcperneg 0.0268139759 0.6596521039 -0.00358985401 0.6288764765 -0.00252435371
iphoneperunc 0.0125533395 0.1714356260 0.16666048711 0.2427354166 0.17941111799
samsungperunc 0.1037669940 0.3467050878 0.10280445279 0.6164418804 0.08321770131
sonyperunc -0.0008061390 0.0332332811 -0.00286112027 -0.0024047420 -0.00271099185
nokiaperunc 1.0000000000 0.0123634536 0.09833647231 0.0031802648 0.09885919175
htcperunc 0.0123634536 1.0000000000 0.00096940171 0.3330219017 0.00067263896
iosperpos 0.0983364723 0.0009694017 1.00000000000 -0.0097122766 0.93238233614
googleperpos 0.0031802648 0.3330219017 -0.00971227657 1.0000000000 -0.00920265496
iosperneg 0.0988591918 0.0006726390 0.93238233614 -0.0092026550 1.00000000000
googleperneg -0.0001365632 0.2808931406 -0.01067564845 0.9574098116 -0.01011547688
iosperunc 0.1577138419 0.0084370013 0.90507944091 -0.0095235760 0.89981887121
googleperunc 0.0041802716 0.3945515791 -0.00605958227 0.8870329991 -0.00574162447
iphonesentiment -0.0361668073 -0.1141712521 -0.01575797821 -0.1372614910 -0.01017931265
googleperneg iosperunc googleperunc iphonesentiment
iphone 0.1387423597 -0.0203681182 0.0678592347 0.014858654
samsunggalaxy 0.2909745336 -0.0153292775 0.1422517633 -0.359172760
sonyxperia -0.0085698468 -0.0148024105 -0.0079160304 -0.233169880
nokialumina 0.0006534676 0.0528866876 0.0079987614 -0.055961769
htcphone 0.0207261368 -0.0026662299 0.0133049541 -0.051284868
ios -0.0180284915 0.1170349668 -0.0102331140 0.001656417
googleandroid 0.7165147742 -0.0163771745 0.3719984702 -0.189142050
iphonecampos 0.1243547611 -0.0010370936 0.0730039141 -0.029731217
samsungcampos 0.3573624065 0.0448897145 0.1591714963 -0.112743311
sonycampos 0.0084545596 -0.0064206991 -0.0034336603 -0.090665090
nokiacampos 0.0039406908 0.1651880784 0.0125178481 -0.033374561
htccampos 0.1772296141 -0.0060785851 0.1000310846 -0.120434115
iphonecamneg 0.4680746932 -0.0107487208 0.2410025125 -0.083963139
samsungcamneg 0.7942819521 0.0470453605 0.3421196381 -0.185988857
sonycamneg 0.0251264773 -0.0028646448 -0.0015319542 -0.024826403
nokiacamneg -0.0004450102 0.1436761784 0.0037721473 -0.033069469
htccamneg 0.6526440067 -0.0101911803 0.3337273887 -0.222972178
iphonecamunc 0.0748583656 -0.0013364593 0.0581386691 0.001443485
samsungcamunc 0.4766899704 0.0576123258 0.2694315123 -0.138045912
sonycamunc -0.0042044682 -0.0044625643 -0.0023864893 -0.050326854
nokiacamunc 0.0012988106 0.1735035602 0.0068285408 -0.031549730
htccamunc 0.2275768031 -0.0051864137 0.1624307557 -0.148881468
iphonedispos 0.1470225674 0.0247667616 0.1796863033 0.014546824
samsungdispos 0.5799514805 0.0572875968 0.6361031491 -0.099262059
sonydispos 0.0017093490 -0.0035623113 -0.0019050522 -0.038635303
nokiadispos -0.0026677068 0.1272636476 -0.0015142114 -0.025922378
htcdispos 0.1092388830 0.0005786204 0.1240182192 -0.060405793
iphonedisneg 0.2136404410 0.0182216460 0.2044162638 0.003144905
samsungdisneg 0.8266039307 0.0507296081 0.7355261466 -0.139964721
sonydisneg 0.0019065213 -0.0015012009 -0.0008028119 -0.019956110
nokiadisneg -0.0028569223 0.1394095914 -0.0016216116 -0.028758588
htcdisneg 0.6983625307 0.0098165195 0.6431743675 -0.192727267
iphonedisunc 0.1060835760 0.0301070415 0.1722760448 0.027172723
samsungdisunc 0.5127319014 0.0399508627 0.7384565052 -0.059548267
sonydisunc -0.0030380429 -0.0032245366 -0.0017244171 -0.032137154
nokiadisunc -0.0022863969 0.1626898312 -0.0012977769 -0.023971988
htcdisunc 0.4065686064 0.0196765106 0.5934935043 -0.132952797
iphoneperpos 0.2188475265 0.2118092692 0.2376254310 0.029637900
samsungperpos 0.4412290699 0.1370566656 0.4275422572 -0.081063185
sonyperpos 0.0080695911 -0.0044727090 -0.0023919145 -0.038912744
nokiaperpos -0.0008238620 0.1359424951 0.0031408747 -0.041594613
htcperpos 0.3584582984 -0.0001889917 0.3683266512 -0.178427038
iphoneperneg 0.3486853181 0.2557356982 0.2962268490 -0.004804058
samsungperneg 0.7963651128 0.1031577743 0.6412286948 -0.138656977
sonyperneg 0.0121404799 -0.0022095991 -0.0011816490 -0.030850090
nokiaperneg -0.0016059114 0.1280016003 0.0016351213 -0.044219386
htcperneg 0.6389410325 0.0003615931 0.5399024601 -0.209196046
iphoneperunc 0.1962538259 0.1817828791 0.2971400100 0.037199859
samsungperunc 0.5415039792 0.0538973132 0.7398874595 -0.057919616
sonyperunc -0.0026432711 -0.0028055314 -0.0015003415 -0.018084032
nokiaperunc -0.0001365632 0.1577138419 0.0041802716 -0.036166807
htcperunc 0.2808931406 0.0084370013 0.3945515791 -0.114171252
iosperpos -0.0106756484 0.9050794409 -0.0060595823 -0.015757978
googleperpos 0.9574098116 -0.0095235760 0.8870329991 -0.137261491
iosperneg -0.0101154769 0.8998188712 -0.0057416245 -0.010179313
googleperneg 1.0000000000 -0.0104682305 0.7561184782 -0.163919084
iosperunc -0.0104682305 1.0000000000 -0.0059418502 -0.011787428
googleperunc 0.7561184782 -0.0059418502 1.0000000000 -0.070284159
iphonesentiment -0.1639190837 -0.0117874280 -0.0702841593 1.000000000
# returns correlation greater than .9
corr_df_big <- correlate(iphone_smallMatrix, diagonal = NA) %>% stretch()
Correlation method: 'pearson'
Missing treated using: 'pairwise.complete.obs'
corr_df_big_filtered <- corr_df_big %>% filter(r > .9)
#corr_filtered_90_tokeep <- corr_df_big %>% filter(r < .9 & r > -.9)
#sort(corr_filtered_90_tokeep$r)
Which variables will I keep? I copied corr_df_big_filtered into a spreadsheet and removed all duplicates.
googleperneg googleperpos htcdispos htcphone ios iosperneg iosperpos iosperunc iphone nokiacamneg nokiacampos nokiacamunc nokiadisneg nokiadispos nokiadisunc nokiaperneg nokiaperpos nokiaperunc samsungdisneg samsungdispos samsungdisunc samsungperneg samsungperunc
#columns to remove
corr_to_remove <- c("googleperneg","googleperpos","htcdispos","htcphone","ios","iosperneg","iosperpos","iosperunc","iphone","nokiacamneg","nokiacampos","nokiacamunc","nokiadisneg","nokiadispos","nokiadisunc","nokiaperneg","nokiaperpos","nokiaperunc","samsungdisneg","samsungdispos","samsungdisunc","samsungperneg","samsungperunc")
iphoneDFBigCOR <- iphone_smallMatrix[ , -which(names(iphone_smallMatrix) %in% corr_to_remove)]
names(iphoneDFBigCOR)
[1] "samsunggalaxy" "sonyxperia" "nokialumina" "googleandroid" "iphonecampos"
[6] "samsungcampos" "sonycampos" "htccampos" "iphonecamneg" "samsungcamneg"
[11] "sonycamneg" "htccamneg" "iphonecamunc" "samsungcamunc" "sonycamunc"
[16] "htccamunc" "iphonedispos" "sonydispos" "iphonedisneg" "sonydisneg"
[21] "htcdisneg" "iphonedisunc" "sonydisunc" "htcdisunc" "iphoneperpos"
[26] "samsungperpos" "sonyperpos" "htcperpos" "iphoneperneg" "sonyperneg"
[31] "htcperneg" "iphoneperunc" "sonyperunc" "htcperunc" "googleperunc"
[36] "iphonesentiment"
# Let's sample the data before using RFE
set.seed(123)
iphoneSample <- iphone_smallMatrix[sample(1:nrow(iphone_smallMatrix), 1000, replace=FALSE),]
# Set up rfeControl with randomforest, repeated cross validation and no updates
ctrl <- rfeControl(functions = rfFuncs,
method = "repeatedcv",
repeats = 5,
verbose = FALSE)
# Use rfe and omit the response variable (attribute 59 iphonesentiment)
rfeResultsBIG <- rfe(iphoneSample[,1:58],
iphoneSample$iphonesentiment,
sizes=(1:58),
rfeControl=ctrl)
# Get results
rfeResultsBIG
# Plot results
plot(rfeResultsBIG, type=c("g", "o"))
BIG RFE
# create new data set with rfe recommended features
iphoneDFBigRFE <- iphone_smallMatrix[,predictors(rfeResultsBIG)]
# add the dependent variable to iphoneRFE
iphoneDFBigRFE$iphonesentiment <- iphone_smallMatrix$iphonesentiment
# review outcome
str(iphoneDFBigRFE)
My_Data_Sets
iPhoneBig - iphoneDFBig <- iphone_smallMatrix - iphoneDFBigCOR <- - iphoneDFBigNZV <- - iphoneDFBigRFE <- iphoneDFBigRFE - iphoneDFBigRecoded <- optional tasks - iphoneDFBigPCA <- optional tasks
# create 10-fold cross validation fitcontrol
fitControl <- trainControl(method = "cv", number = 10)
# rename variables as necessary
iphoneDFBig <- iphone_smallMatrix
# convert variable types, categorical
iphoneDFBig$iphonesentiment <- as.factor(iphoneDFBig$iphonesentiment)
Train and Test Set:
# Create Train and Test Set for iphoneDFBig
# create 75% sample of row indices
in_training <-createDataPartition(iphoneDFBig$iphonesentiment, p = .7, list = FALSE)
# create 75% sample of data and save it to trainData
trainData_iphoneDFBig <- iphoneDFBig[in_training, ]
# create 25% sample of data and save it to test_data
testData_iphoneDFBig <- iphoneDFBig[-in_training, ]
# verify split percentages
nrow(trainData_iphoneDFBig) / nrow(iphoneDFBig)
#c5
c5_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "C5.0",
trControl = fitControl)
# randomforest
rf_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "rf",
trControl = fitControl)
# svm (kernlab)
svm_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "svmLinear",
trControl = fitControl)
# kknn
kknn_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "kknn",
trControl = fitControl)
# gbm
#gbm_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "gbm",
# trControl = fitControl)
Compare Accuracy on Prediction Results:
#c5
prediction_c5_iphoneDFBig <- predict(c5_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_c5_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
#randomforest
prediction_rf_iphoneDFBig <- predict(rf_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_rf_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
#svm
prediction_svm_iphoneDFBig <- predict(svm_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_svm_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
# kknn
prediction_kknn_iphoneDFBig <- predict(kknn_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_kknn_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
# gbm
#prediction_gbm_iphoneDFBig <- predict(gbm_iphoneDFBig, testData_iphoneDFBig)
#Model summary for comparisons
Accuracy Kappa 0.7763496 0.5644448 Accuracy Kappa 0.7732648 0.5634731 Accuracy Kappa 0.7115681 0.4174966 Accuracy Kappa 0.3311054 0.1636461
modelData_iphoneDFBig <- resamples(list(C50 = c5_iphoneDFBig, randomForest = rf_iphoneDFBig, svMLinear = svm_iphoneDFBig,kknn = kknn_iphoneDFBig))
summary(modelData_iphoneDFBig)
# convert variable types, categorical
iphoneDFBigCOR$iphonesentiment <- as.factor(iphoneDFBigCOR$iphonesentiment)
Train and Test Set:
# Create Train and Test Set for iphoneDFBig
# create 75% sample of row indices
in_training <-createDataPartition(iphoneDFBig$iphonesentiment, p = .7, list = FALSE)
# create 75% sample of data and save it to trainData
trainData_iphoneDFBig <- iphoneDFBig[in_training, ]
# create 25% sample of data and save it to test_data
testData_iphoneDFBig <- iphoneDFBig[-in_training, ]
# verify split percentages
nrow(trainData_iphoneDFBig) / nrow(iphoneDFBig)
#c5
c5_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "C5.0",
trControl = fitControl)
# randomforest
rf_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "rf",
trControl = fitControl)
# svm (kernlab)
svm_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "svmLinear",
trControl = fitControl)
# kknn
kknn_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "kknn",
trControl = fitControl)
# gbm
#gbm_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "gbm",
# trControl = fitControl)
Compare Accuracy on Prediction Results:
#c5
prediction_c5_iphoneDFBig <- predict(c5_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_c5_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
#randomforest
prediction_rf_iphoneDFBig <- predict(rf_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_rf_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
#svm
prediction_svm_iphoneDFBig <- predict(svm_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_svm_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
# kknn
prediction_kknn_iphoneDFBig <- predict(kknn_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_kknn_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
modelData_iphoneDFBig <- resamples(list(C50 = c5_iphoneDFBig, randomForest = rf_iphoneDFBig, svMLinear = svm_iphoneDFBig,kknn = kknn_iphoneDFBig))
summary(modelData_iphoneDFBig)
# convert variable types, categorical
iphoneDFBigCOR$iphonesentiment <- as.factor(iphoneDFBigCOR$iphonesentiment)
Train and Test Set:
# Create Train and Test Set for iphoneDFBig
# create 75% sample of row indices
in_training <-createDataPartition(iphoneDFBig$iphonesentiment, p = .7, list = FALSE)
# create 75% sample of data and save it to trainData
trainData_iphoneDFBig <- iphoneDFBig[in_training, ]
# create 25% sample of data and save it to test_data
testData_iphoneDFBig <- iphoneDFBig[-in_training, ]
# verify split percentages
nrow(trainData_iphoneDFBig) / nrow(iphoneDFBig)
#c5
c5_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "C5.0",
trControl = fitControl)
# randomforest
rf_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "rf",
trControl = fitControl)
# svm (kernlab)
svm_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "svmLinear",
trControl = fitControl)
# kknn
kknn_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "kknn",
trControl = fitControl)
# gbm
#gbm_iphoneDFBig <- train(iphonesentiment ~., data = trainData_iphoneDFBig, method = "gbm",
# trControl = fitControl)
Compare Accuracy on Prediction Results:
#c5
prediction_c5_iphoneDFBig <- predict(c5_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_c5_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
Accuracy Kappa
0.7763496 0.5644448
#randomforest
prediction_rf_iphoneDFBig <- predict(rf_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_rf_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
Accuracy Kappa
0.7732648 0.5634731
#svm
prediction_svm_iphoneDFBig <- predict(svm_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_svm_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
Accuracy Kappa
0.7115681 0.4174966
# kknn
prediction_kknn_iphoneDFBig <- predict(kknn_iphoneDFBig, testData_iphoneDFBig)
postResample(prediction_kknn_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
Accuracy Kappa
0.3311054 0.1636461
modelData_iphoneDFBig <- resamples(list(C50 = c5_iphoneDFBig, randomForest = rf_iphoneDFBig, svMLinear = svm_iphoneDFBig,kknn = kknn_iphoneDFBig))
summary(modelData_iphoneDFBig)
# Create a confusion matrix from random forest predictions
cmC5 <- confusionMatrix(prediction_c5_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
cmC5
Confusion Matrix and Statistics
Reference
Prediction 0 1 2 3 4 5
0 398 1 0 2 3 9
1 0 0 0 0 0 0
2 0 0 19 0 0 0
3 2 0 0 222 0 2
4 2 0 1 1 138 8
5 186 116 116 131 290 2243
Overall Statistics
Accuracy : 0.7763
95% CI : (0.7629, 0.7894)
No Information Rate : 0.5815
P-Value [Acc > NIR] : < 0.00000000000000022
Kappa : 0.5644
Mcnemar's Test P-Value : NA
Statistics by Class:
Class: 0 Class: 1 Class: 2 Class: 3 Class: 4 Class: 5
Sensitivity 0.6769 0.00000 0.139706 0.62360 0.32019 0.9916
Specificity 0.9955 1.00000 1.000000 0.99887 0.99653 0.4846
Pos Pred Value 0.9637 NaN 1.000000 0.98230 0.92000 0.7278
Neg Pred Value 0.9454 0.96992 0.969775 0.96343 0.92166 0.9765
Prevalence 0.1512 0.03008 0.034961 0.09152 0.11080 0.5815
Detection Rate 0.1023 0.00000 0.004884 0.05707 0.03548 0.5766
Detection Prevalence 0.1062 0.00000 0.004884 0.05810 0.03856 0.7923
Balanced Accuracy 0.8362 0.50000 0.569853 0.81123 0.65836 0.7381
cmRM <- confusionMatrix(prediction_rf_iphoneDFBig, testData_iphoneDFBig$iphonesentiment)
cmRM
Confusion Matrix and Statistics
Reference
Prediction 0 1 2 3 4 5
0 397 0 1 3 4 11
1 1 0 0 1 1 4
2 0 0 19 0 0 4
3 1 1 0 226 2 5
4 5 0 0 3 147 19
5 184 116 116 123 277 2219
Overall Statistics
Accuracy : 0.7733
95% CI : (0.7598, 0.7863)
No Information Rate : 0.5815
P-Value [Acc > NIR] : < 0.00000000000000022
Kappa : 0.5635
Mcnemar's Test P-Value : NA
Statistics by Class:
Class: 0 Class: 1 Class: 2 Class: 3 Class: 4 Class: 5
Sensitivity 0.6752 0.000000 0.139706 0.63483 0.34107 0.9810
Specificity 0.9942 0.998145 0.998934 0.99745 0.99219 0.4988
Pos Pred Value 0.9543 0.000000 0.826087 0.96170 0.84483 0.7311
Neg Pred Value 0.9450 0.969869 0.969744 0.96443 0.92357 0.9497
Prevalence 0.1512 0.030077 0.034961 0.09152 0.11080 0.5815
Detection Rate 0.1021 0.000000 0.004884 0.05810 0.03779 0.5704
Detection Prevalence 0.1069 0.001799 0.005913 0.06041 0.04473 0.7802
Balanced Accuracy 0.8347 0.499072 0.569320 0.81614 0.66663 0.7399